from wal.control.models import Control, DetalleControl, Evaluacion, Accion, Stock
from django.contrib import admin


class AdminControl(admin.ModelAdmin):
        list_display = ('nombre','pedido','cliente','fecha','responsable','unidades','kgreal','kgproc',)
        search_fields = ('nombre','pedido','cliente','fecha','responsable',)
        ordering = ('fecha',)

admin.site.register(Control,AdminControl)

class AdminDetalleControl(admin.ModelAdmin):
        list_display = ('control','articulo','cantidad',)
        search_fields = ('control','articulo','cantidad',)
        
admin.site.register(DetalleControl,AdminDetalleControl)

class AdminEvaluacion(admin.ModelAdmin):
        list_display = ('nombre','fecha','motivo',)
        search_fields = ('nombre','fecha',)
        
admin.site.register(Evaluacion,AdminEvaluacion)

class AdminAccion(admin.ModelAdmin):
        list_display = ('accion','plazo',)
        search_fields = ('accion','plazo',)
        
admin.site.register(Accion,AdminAccion)

class AdminStock(admin.ModelAdmin):
        list_display = ('pedido','articulo',)
        search_fields = ('pedido','articulo',)
        
admin.site.register(Stock,AdminStock)